package moxl.relaxng.model;

public class SchemaNotWellDefinedException extends Exception
{
	private final Pattern offendingPattern;

	public SchemaNotWellDefinedException(String message, Pattern offendingPattern)
	{
		super(message);
		this.offendingPattern = offendingPattern;
	}

	public SchemaNotWellDefinedException(String message, Throwable cause, Pattern offendingPattern)
	{
		super(message, cause);
		this.offendingPattern = offendingPattern;
	}

	@Override
	public String getMessage()
	{
		return offendingPattern + ": " + super.getMessage();
	}
}
